package com.xingkeduo.pojo.enums;

/**
 * 
 * 类说明 店铺终端类型枚举类  
 * @author: pantong E-mail:pantong@xingkeduo.com
 * @date: 2019年7月19日 下午3:57:13
 */
public enum ShopsTerminal {
	Physical(1, "实体店"),
    Box(2, "Box店");

    private Integer value;

    private String desc;

    ShopsTerminal(Integer value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    public Integer getValue() {
        return value;
    }

    public void setValue(Integer value) {
        this.value = value;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    //获取枚举对象
    public static ShopsTerminal get(Integer value){
        for(ShopsTerminal shopsType: ShopsTerminal.values()) {
            if (shopsType.getValue().equals(value)) {
                return shopsType;
            }
        }
        return null;
    }

}
